1. Field of the Invention
The invention relates generally to the detection of address and protocol information in Ethernet packets, and more particularly, to detection by Ethernet Media Access Controllers (MAC).
2. Description of the Related Art
Ethernet is a commonly used local area network scheme in which multiple stations are connected to a single shared serial data path. Typically, only one station can transmit data onto the path at a time. A station connected to the path transmits data in the form of a packet that includes a destination address. The packet propagates throughout the network medium and is received by all other stations. The addressed station copies the entire packet as it goes by; the others reject the packet after determining that it is addressed to another station.
The drawing of FIG. 1 shows a representative Ethernet packet. Each packet comprises a series of 8-bit bytes of digital information. Each packet is preceded by a seven byte preamble composed of alternating 1s and .phi.s. The preamble is followed by a one byte long start frame delimiter (SFD) which presents the following eight bit sequence: 10101011. After the SFD, follows a packet that can vary in length from 64 to 1518 bytes. In particular, six bytes (48 bits) of destination address immediately follow the preamble. The destination address designates the intended destination of the packet. After the destination address, follow six bytes of source address which designate the source of the packet. After that, there are two bytes that designate the packet length. Then follow between 46 and 1500 bytes of data. Finally, there are four bytes which constitute the frame checking sequence (FCS) for checking errors.
A Media Access Controller (MAC) serves as an interface between a shared data path and the stations connected to that path. Each node connected to the network includes a MAC which performs a number of functions involved in the transmission and reception of data packets. For example, during the transmission of data, the MAC assembles the data to be transmitted into a packet with address and error detection fields. Conversely, during the reception of a packet, the MAC disassembles the packet and performs address checking and error detection. In addition, the MAC typically performs encoding/decoding of digital signals transmitted over the shared path and performs preamble generation/removal as well as bit transmission/reception.
Since packet traffic on the shared serial data path can be heavy, with little time between packets, each MAC must be able to quickly assess whether a received packet is addressed to its station and should be copied or is addressed to another station and should be ignored. Each MAC has at least one physical address assigned to it.
Typically, a MAC includes a receive FIFO (first-in-first-out) memory which is used to temporarily store data captured from the shared path. In an earlier MAC, as the packet passes by on the shared path, the MAC takes the serial information and assembles it into eight bit frames which are loaded frame-by-frame into a receive FIFO. As the frames are loaded and the packet continues to pass by on the shared path, the MAC determines whether the destination address in the packet corresponds to the physical address of the MAC. If there is a match, then the MAC captures the entire packet. If there is no match, then the packet is rejected and the segment stored in the FIFO is flushed.
In some instances, however, a MAC will be required to receive packets on behalf of more than one station. For example, referring to the illustrative drawing of FIG. 2, there is shown a network which comprises three separate local area networks. First and second local area networks 20 and 22 are Ethernet networks. A third local area network 24 is an FDDI (Fiber Distributed Data Interface) Loop. The two Ethernet networks 20, 22, of course, utilize the Ethernet protocol on Ethernet data paths 26 and 28, respectively. The FDDI Loop, uses an FDDI protocol on data path 30. The first Ethernet network includes a plurality of workstations 20-1, 20-2 through 20-N. Similarly, the second Ethernet network also includes a plurality of workstation nodes 22-1, 22-2 through 22-M. Similarly, the FDDI Loop 24 includes a plurality of stations including the station labeled Bridge A and the station labeled Bridge B.
Each workstation node on the first and second Ethernet networks 20, 22 includes a MAC which serves as an interface between the respective shared data paths 26, 28 and the individual nodes. Bridge A and Bridge B serve to transfer information between respective workstations on the first Ethernet network 20 and workstations on the second Ethernet network 22. It is possible, for example, that the respective first and second Ethernet networks each have a large number, perhaps thousands, of workstations connected to them.
The MACs at Bridge A and at Bridge B must be able to compare the destination address in each received packet with a very large number of station addresses to determine whether or not the packet should be received. For example, the MAC at Bridge A, which is part of the second Ethernet network 22, must be able to determine whether or not a packet provided on data path 28 is destined for a workstation on the first Ethernet network 20. It must capture packets addressed to destination address 157E, 231A and 34E5, the physical addresses of workstations 20-1, 20-2 and 20-N. Conversely, the MAC at Bridge B, which is part of the first Ethernet network, must capture packets on data path 26 addressed to 562C, 4D5 and 13EB, the physical addresses of workstations 2-1, 22-2 and 22-M on the second Ethernet network 22.
Each MAC has a limited number of physical addresses that it can recognize. As a consequence, software hash techniques often are used to determine whether or not a particular Ethernet packet should be accepted or rejected. Unfortunately, such hash techniques can be imprecise and can lead to the acceptance of packets that should have been rejected. Moreover, such hash techniques can be relatively time consuming and can burden system resources. Since, for example, the data rate in the FDDI Loop is on order of ten times that of the Ethernet networks, speed in packet accept/reject can be imperative. Unfortunately, software hash techniques tend to slow down the packet processing.
Thus, there has been a need for an improved mechanism for determining whether or not to accept or reject an Ethernet packet received by a MAC. The present invention meets this need.